package com.web_bloks.widget.client;

import com.google.gwt.dom.client.Element;
import com.google.gwt.user.client.ui.Widget;

/**
 * 
 * @author Jean-Lou Dupont
 *
 */
public class CollectionableWidget 
	extends Widget
	implements WidgetEx {

	String collectionName = null;
	
	String id = null;
	
	public CollectionableWidget() {
		super();
	}
	
	public void setOriginCollection(String collectionName) {
		this.collectionName = collectionName;
	}
	
	public String getOriginCollection() {
		return this.collectionName;
	}
	
	public void initFromDOMElement(Element parent, Element el) {
		throw new RuntimeException("CollectionableWidget.initFromDOMElement: must be defined in subclass");
	}
	
	public void setId(String id) {
		this.id = new String(id);
	}
	public String getId() {
		return this.id;
	}
	
}//ENDCLASS